<!DOCTYPE html>
<html>
<head>
    <title>后台</title>
    <meta charset="utf-8">
    <!-- public -->
    <link rel="stylesheet" href="<?=HW_CSS?>font.css">
    <link rel="stylesheet" href="<?=HW_CSS?>base.css">
    <link rel="stylesheet" href="<?=HW_CSS?>bootstrap/css/bootstrap.min.css">
    <link rel="stylesheet" href="<?=HW_CSS?>style.css">
    <link rel="stylesheet" href="<?=HW_CSS?>main_content.css">
</head>
<style>
    input[type=file]{
        display: none;
    }
    .img-box{
        position:relative;
    }
    .img-box .tip{
        position: absolute;
        
    }
    .news-del{
        width: 15px;
    }
</style>
<body>
    <form class="form-horizontal" action="<?=base_url().'Admin/Video/addVideo'?>" method="POST">
        <!-- toolbar_container -->
        <div id="toolbar_container">
            <div class="tb_item">
                <button type="submit" id="submitactivity">保存</button>
            </div>
        </div>
        <!-- 基本信息 -->
        <div class="panel-group">
            <div class="panel panel-default">
                <div class="panel-heading">
                    <h4 class="panel-title">
                        <a role="button" data-toggle="collapse" href="#collapseOne">
                            视频信息
                        </a>
                    </h4>
                </div>
                <div id="collapseOne" class="panel-collapse collapse in">
                    <div class="panel-body">
                        <div class="form-group">
                            <input type='hidden' name='id' value="<?=isset($info)?$info['id']:'0'?>">
                            <label for="" class="col-sm-2 control-label">视频标题<span>*</span>：</label>
                            <div class="col-sm-8">
                                <input type="text" class="form-control" placeholder="请输入少于20个汉字" name="theme" required value="<?=isset($info)?$info['theme']:''?>" autocomplete="off">
                            </div>
                        </div>
                        <div class="form-group img-box" data-num='1' id="default_img">
                            <label for="" class="col-sm-2 control-label">封面<span>*</span>：</br>推荐尺寸（375*125）</label>
                            <div class="col-sm-3">
                                <?php if(isset($info) && $info['default_img']){?>
                                <div class="img_item">
                                    <img src="<?=$info['default_img']?>" />
                                    <input type="hidden" name="default_img" value="<?=$info['default_img']?>">
                                    <a class="del_img del">×</a>
                                </div>
                                <?php }?>
                                <img src="<?=HW_IMG?>add.png" alt="" name="default_img" class='add_img'>
                                <input type="file" name="images" id="">
                            </div>
                        </div>
                        <div class="form-group">
                            <label for="" class="col-sm-2 control-label">链接<span>*</span>：</label>
                            <div class="col-sm-8">
                                <input type="text" required class="form-control" name="link" value="<?=isset($info)?$info['link']:''?>">
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </form>
    <div class="mud">
        <div class="upload_success">正在上传...</div>
    </div>
</body>
<script type="text/javascript">
    var uploadUrl = "<?=base_url().'Api/Upload/ajax_upload'?>";
</script>
<script type="text/javascript" src="<?=HW_STA?>lib/require.js" data-main="<?=HW_STA?>module/video/videodetail.js"></script>
<script src="<?=HW_STA?>js/jquery-2.0.2.min.js"> </script>
</html>